﻿using SqlSugar;
using System;

namespace SCM.Model.DBEntity
{
    /// <summary>
    /// 豁免条款表
    /// </summary>
    [SugarTable("T_Exemption")]
    public class T_Exemption
    {
        /// <summary>
        /// 豁免条款ID
        /// </summary>
        public string ID { get; set; }

        /// <summary>
        /// 豁免条款编号
        /// </summary>
        public string Code { get; set; }

        /// <summary>
        /// 豁免条款中文内容
        /// </summary>
        public string CNContent { get; set; }

        /// <summary>
        /// 豁免条款英文内容
        /// </summary>
        public string ENContent { get; set; }

        /// <summary>
        /// 到期时间
        /// </summary>
        public DateTime? ExpireDate { get; set; }

        /// <summary>
        /// 到期时间
        /// </summary>
        [SugarColumn(IsIgnore = true)]
        public string ExpireDateStr { get { return ExpireDate.HasValue ? ExpireDate.Value.ToString("yyyy-MM-dd HH:mm:ss") : string.Empty; } }

        /// <summary>
        /// 备注
        /// </summary>
        public string Remark { get; set; }

        /// <summary>
        /// 创建时间
        /// </summary>
        public DateTime? CreateTime { get; set; } = DateTime.Now;

        /// <summary>
        /// 创建时间
        /// </summary>
        [SugarColumn(IsIgnore = true)]
        public string CreateTimeStr { get { return CreateTime.HasValue ? CreateTime.Value.ToString("yyyy-MM-dd HH:mm:ss") : string.Empty; } }

        /// <summary>
        /// 最后编辑时间
        /// </summary>
        public DateTime? ModifyTime { get; set; }

        /// <summary>
        /// 最后编辑时间
        /// </summary>
        [SugarColumn(IsIgnore = true)]
        public string ModifyTimeStr { get { return ModifyTime.HasValue ? ModifyTime.Value.ToString("yyyy-MM-dd HH:mm:ss") : string.Empty; } }
    }
}